//iframe change
function setIframeHeight(){
	for(var i=0; i<$("iframe",parent.document).length;i++){
		if($("iframe",parent.document)[i].contentWindow.document.body.innerHTML==document.body.innerHTML){
			var h = $(document).contents().find("body").height();
			$($("iframe",parent.document)[i]).height(h);
			return;
		}	
	}
}
/** 
 * @Description 计算整年前和后日期
 * @author yongfeng.hou
 * @param form 开始日期
 * @param years 跨几年整数
 * @param sp 分割符 必须跟form格式一样
 * @param oper + 后 - 前
 * @return 输出格式与输入格式相同
 */
function toyears(from,years,sp,oper) {if(!from||!years||!sp||!oper){return "";}if(from.indexOf(sp)<1){return "";}if(oper!="+"&&oper!="-"){return "";}var forms = from.split(sp);var year = oper=="+"?(parseInt(forms[0])+parseInt(years)):(parseInt(forms[0])-parseInt(years));var month = forms[1];var date = forms[2];var to = year  + "/" + month + "/" + date;var myDate = new Date(to);myDate = oper=="+"?(myDate.getTime()-24*60*60*1000):(myDate.getTime()+24*60*60*1000);var myDate1 = new Date(myDate);return myDate1.getFullYear() + sp + parseInt(myDate1.getMonth()+1) + sp	+ myDate1.getDate();}
/** 
 * @Description 计算几天后日期
 * @author yongfeng.hou
 * @param form 开始日期
 * @param days 天数
 * @param sp 分割符 必须跟form格式一样
 * @param oper + 后 - 前
 * @return 输出格式与输入格式相同
 */
function todays(from,days,sp,oper) {if(!from||!days||!sp||!oper){return "";}if(from.indexOf(sp)<1){return "";}if(oper!="+"&&oper!="-"){return "";}var forms = from.split(sp);var year = forms[0];var month = forms[1];var date = forms[2];var to = year  + "/" + month + "/" + date;var myDate = new Date(to);myDate = oper=="+"?(myDate.getTime()+parseInt(days)*24*60*60*1000):(myDate.getTime()-parseInt(days)*24*60*60*1000);var myDate1 = new Date(myDate);return myDate1.getFullYear() + sp + parseInt(myDate1.getMonth()+1) + sp	+ myDate1.getDate();
}